<!DOCTYPE html PUBLIC "-//W3C//DTD XHTML 1.0 Transitional//EN" "http://www.w3.org/TR/xhtml1/DTD/xhtml1-transitional.dtd">
<html xmlns="http://www.w3.org/1999/xhtml" lang="hu" xml:lang="hu">
    <head>
	<meta http-equiv="content-Type" content="text/html; charset=utf-8" />
	<title><?=$page_title?></title>
	<script type="text/javascript" src="<?=base_url()?>/js/jquery-1.3.2.min.js"></script>
    </head>
<body>
<div id="login_div">
    <a href="news">Hírek</a> | <a href="chat">Chat</a> | <a href="forum">Fórum</a>
    <? if($login_message) { ?>
    <p>login message: <?= $login_message ?></p>
    <? } ?>
    <? if(is_object($logged_in_user)) { ?>
    <p>logged in: <?= $logged_in_user->alias_name ?></p>
    <form id="logout_form" name="logout_form" action="base/userlogin/logout" method="post">
	<input type="hidden" id="controller" name="controller" value="<?=$controller?>" />
	<input type="submit" value="log out" />
    </form>
    <? } else { ?>
    <form id="login_form" name="login_form" action="base/userlogin/login" method="post">
	<input type="text" id="username" name="username" value="<?=$username?>" />
	<input type="password" id="password" name="password" value="" />
	<input type="hidden" id="controller" name="controller" value="<?=$controller?>" />
	<input type="submit" value="log in" />
    </form>
    <? } ?>
</div>